<?php
/**
 * Vypisovaci modul ano/nie
 * @author Tomas Srna
 * @package bakalarka
 */

class YesNoWriter implements Writer
{
	public $raw = NULL;
	
	public function set($raw)
	{
		$this->raw = $raw;
		return $this;
	}
	
	public function __toString()
	{
		return F::he(($this->raw == 1 ? L::selected()->yes : L::selected()->no));
	}
	
	public function write()
	{
		echo (string)$this;
	}
}
